/* SETTINGS */

/* General */
// Startup
user_pref("browser.sessionstore.resume_session_once", true);
user_pref("browser.shell.checkDefaultBrowser", false);

// Tabs
// Show an image preview when you hover on a tab
user_pref("browser.tabs.hoverPreview.showThumbnails", false);

// Language and Appearance
// Website appearance
user_pref("layout.css.prefers-color-scheme.content-override", 0);

// Browsing
// Enable picture-in-picture video controls
user_pref("media.videocontrols.picture-in-picture.video-toggle.enabled", false);
// Control media via keyboard, headset, or virtual interface
user_pref("media.hardwaremediakeys.enabled", false);
// Recommend extensions as you browse
user_pref("browser.newtabpage.activity-stream.asrouter.userprefs.cfr.addons", false);
// Recommend features as you browse
user_pref("browser.newtabpage.activity-stream.asrouter.userprefs.cfr.features", false);

/* Home */
// New Windows and Tabs
// Homepage and New Windows
user_pref("browser.startup.homepage", "chrome://browser/content/blanktab.html");
// New Tabs
user_pref("browser.newtabpage.enabled", false);

// Firefox Home Content
// Web Search
user_pref("browser.newtabpage.activity-stream.showSearch", false);
// Shortcuts
user_pref("browser.newtabpage.activity-stream.feeds.topsites", false);
user_pref("browser.newtabpage.activity-stream.showSponsoredTopSites", false);
// Visited Pages
user_pref("browser.newtabpage.activity-stream.section.highlights.includeVisited", false);
// Bookmarks
user_pref("browser.newtabpage.activity-stream.section.highlights.includeBookmarks", false);
// Most Recent Download
user_pref("browser.newtabpage.activity-stream.section.highlights.includeDownloads", false);

/* Search */
// Search Bar
// Add search bar in toolbar
user_pref("browser.search.widget.inNavBar", true);
// Search Suggestions
// Provide search suggestions
user_pref("browser.search.suggest.enabled", false);
// Show search suggestions ahead of browsing history in address bar results
user_pref("browser.urlbar.showSearchSuggestionsFirst", false);
// Address Bar
user_pref("browser.urlbar.suggest.clipboard", false);
user_pref("browser.urlbar.suggest.engines", false);
user_pref("browser.urlbar.suggest.topsites", false);

/* Privacy & Security */
// Enhanced Tracking Protection
user_pref("browser.contentblocking.category", "strict");

// Cookies and Site Data
user_pref("privacy.clearOnShutdown_v2.cache", true);
user_pref("privacy.clearOnShutdown_v2.cookiesAndStorage", true);
user_pref("privacy.clearOnShutdown_v2.historyFormDataAndDownloads", false);

// Logins and Passwords
// Ask to save logins and passwords for websites
user_pref("signon.rememberSignons", false);
// Autifill logins and passwords
user_pref("signon.autofillForms", false);
// Suggest and generate strong passwords
user_pref("signon.generation.enabled", false);
// Suggest Firefox Relay email masks to protect your email address
user_pref("signon.firefoxRelay.feature", "disabled");
// Show alerts about passwords for breached wesites
user_pref("signon.management.page.breach-alerts.enabled", false);

// Permissions
// Location
user_pref("permissions.default.geo", 2);
// Camera
user_pref("permissions.default.camera", 2);
// Microphone
user_pref("permissions.default.microphone", 2);
// Notifications
user_pref("permissions.default.desktop-notification", 2);
// Virtual Reality
user_pref("permissions.default.xr", 2);

// Firefox Data Collection and Use
// Allow Firefox to send technical and interaction data to Mozilla
user_pref("datareporting.healthreport.uploadEnabled", false);
// Allow Firefox to make personalized extension recommendations
user_pref("browser.discovery.enabled", false);
// Allow Firefox to install and run studies
user_pref("app.shield.optoutstudies.enabled", false);

// Website Advertising Preferences
// Allow websites to perform privacy-preserving ad measurement
user_pref("dom.private-attribution.submission.enabled", false);

// Security
// Block dangerous and deceptive content
user_pref("browser.safebrowsing.malware.enabled", false);
user_pref("browser.safebrowsing.phishing.enabled", false);
// Block dangerous downloads
user_pref("browser.safebrowsing.downloads.enabled", false);
// Warn you about unwanted and uncommon software
user_pref("browser.safebrowsing.downloads.remote.block_potentially_unwanted", false);

// HTTPS-Only Mode
// Enable HTTPS-Only Mode in all windows
user_pref("dom.security.https_only_mode", true);

// DNS over HTTPS
// Enable Secure DNS Using:
user_pref("network.trr.mode" 3);
user_pref("network.trr.uri", "https://dns.quad9.net/dns-query");

/* Sync */
user_pref("identity.fxaccounts.enabled", false);

/* More from Mozilla */
user_pref("browser.preferences.moreFromMozilla", false);

/* ADD-ONS MANAGER */

/* Recommendations */
user_pref("extensions.getAddons.showPane", false);

/* Extensions */
// Recommended Extensions
user_pref("extensions.htmlaboutaddons.recommendations.enabled", false);

/* OTHER */

// UI
user_pref("browser.uidensity", 1);
user_pref("browser.toolbars.bookmarks.visibility", "never");
user_pref("browser.aboutwelcome.enabled", false);
user_pref("browser.startup.homepage_override.mstone", "ignore");

// Accessibility
user.pref("accessibility.force_disabled", 1);

// Touchpad Zooming
user_pref("apz.allow_zooming", false);

// Containers
user_pref("privacy.userContext.enabled", true);

// Pocket
user_pref("extensions.pocket.enabled", false);

// Formfill
user_pref("browser.formfill.enable", false);

// WebRTC
user_pref("media.peerconnection.enabled", false);

// XDG Desktop Portal
user_pref("widget.use-xdg-desktop-portal.file-picker", 2);

// Audio and Video
user_pref("media.mediasource.vp9.enabled", false);
user_pref("media.av1.enabled", false);
